package com.speedricemanager.activity.home;

import android.os.Bundle;
import android.widget.Button;
import android.widget.EditText;

import com.jbm.core.iface.IAcross;
import com.speedricemanager.R;
import com.speedricemanager.net.AllNet;
import com.speedricemanager.other.base.BaseAty;

import butterknife.ButterKnife;
import butterknife.InjectView;
import butterknife.OnClick;
import rx.Observable;
import rx.Subscriber;
import rx.functions.Action1;

public class HomeAty extends BaseAty {

    @InjectView(R.id.et)
    EditText et;
    @InjectView(R.id.commit)
    Button commit;

    private AllNet net;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_home_aty);
        ButterKnife.inject(this);
        net = new AllNet(this);
        Observable.create(new Observable.OnSubscribe<String>() {
            @Override
            public void call(Subscriber<? super String> subscriber) {

            }
        }).subscribe(new Action1<String>() {
            @Override
            public void call(String s) {

            }
        });

    }

    @Override
    protected void onComplete(IAcross iAcross, String methodName) {
        super.onComplete(iAcross, methodName);
        if("AuditTaskMould".equals(methodName)){
            messageAlert("成功");
        }

    }

    @OnClick(R.id.commit)
    public void onClick() {
//    net.AuditTaskMould(Integer.parseInt(et.getText().toString()),2,"","","","","","","","","","","",null);
    }
}
